<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
       .box {
           margin: 0 auto;
           width: 100%;
           max-width: 900px;
           min-width: 300px;
       }
       .box div {
           float: left;
           width: 50%;
           height: 400px;
       }
       .box div:nth-child(1) {
           background-color: black;

       }
       .box div:last-child {
           background-color: red;
       }
    </style>
</head>
<body>
   <div class="box">
    <div></div>
    <div></div>
   </div>
</body>
</html>